package com.google.android.exoplayer2.video;

import android.os.Parcel;
import android.os.Parcelable;
import android.os.Parcelable.Creator;
import androidx.annotation.Nullable;
import java.util.Arrays;
import o.anr;

public final class ColorInfo implements Parcelable {
    public static final Creator<ColorInfo> CREATOR = new Creator<ColorInfo>() {
        public /* synthetic */ Object createFromParcel(Parcel parcel) {
            return ˋ(parcel);
        }

        public /* synthetic */ Object[] newArray(int i) {
            return ˎ(i);
        }

        public ColorInfo ˋ(Parcel parcel) {
            return new ColorInfo(parcel);
        }

        public ColorInfo[] ˎ(int i) {
            return new ColorInfo[0];
        }
    };
    public final int ˊ;
    public final int ˋ;
    public final int ˎ;
    @Nullable
    public final byte[] ˏ;
    private int ॱ;

    public ColorInfo(int i, int i2, int i3, @Nullable byte[] bArr) {
        this.ˎ = i;
        this.ˊ = i2;
        this.ˋ = i3;
        this.ˏ = bArr;
    }

    ColorInfo(Parcel parcel) {
        this.ˎ = parcel.readInt();
        this.ˊ = parcel.readInt();
        this.ˋ = parcel.readInt();
        this.ˏ = anr.ˋ(parcel) ? parcel.createByteArray() : null;
    }

    public boolean equals(@Nullable Object obj) {
        if (this == obj) {
            return true;
        }
        if (obj == null || getClass() != obj.getClass()) {
            return false;
        }
        ColorInfo colorInfo = (ColorInfo) obj;
        if (this.ˎ == colorInfo.ˎ && this.ˊ == colorInfo.ˊ && this.ˋ == colorInfo.ˋ && Arrays.equals(this.ˏ, colorInfo.ˏ)) {
            return true;
        }
        return false;
    }

    public String toString() {
        return "ColorInfo(" + this.ˎ + ", " + this.ˊ + ", " + this.ˋ + ", " + (this.ˏ != null) + ")";
    }

    public int hashCode() {
        if (this.ॱ == 0) {
            this.ॱ = ((((((this.ˎ + 527) * 31) + this.ˊ) * 31) + this.ˋ) * 31) + Arrays.hashCode(this.ˏ);
        }
        return this.ॱ;
    }

    public int describeContents() {
        return 0;
    }

    public void writeToParcel(Parcel parcel, int i) {
        parcel.writeInt(this.ˎ);
        parcel.writeInt(this.ˊ);
        parcel.writeInt(this.ˋ);
        anr.ˎ(parcel, this.ˏ != null);
        if (this.ˏ != null) {
            parcel.writeByteArray(this.ˏ);
        }
    }
}
